{// 引入标签库 }
<tagLib name="html" />
<include file="Public:header" />
<load href='__TMPL__Common/js/jquery.bgiframe.js' />
<load href='__TMPL__Common/js/jquery.weebox.js' />
<load href='__TMPL__Common/js/user.js' />
<load href='__TMPL__Common/style/weebox.css' />
<div class="main">
<div class="main_title"><if condition="$order_info['order_status'] eq 0">{%DEAL_ORDER_HANDLE}<else />{%DEAL_ORDER_VIEW}</if>{$order_info.order_sn}

</div>
<script type="text/javascript">
	function viewCancelBox(id){
		$.weeboxs.open(ROOT+'?m=TakeawayOrder&a=cancelbox&id='+id, {contentType:'ajax',showButton:false,title:"撤销订单",width:500,height:160});
	}
</script>
<div class="blank5"></div>

<table class="form" cellpadding=0 cellspacing=0>
	<tr>
		<td colspan=4 class="topTd"></td>
	</tr>
	<tr>
		<td class="item_title">{%ORDER_USER}:</td>
		<td colspan="3" class="item_input">
			{$order_info.user_id|get_user_name_js}
		</td>
	</tr>
	<tr>
		<td class="item_title">{%ORDER_SN}:</td>
		<td colspan="3" class="item_input">{$order_info.order_sn}</td>
	</tr>	
	<tr>
		<td class="item_title">订单状态:</td>
		<td colspan="3" class="item_input">{$order_info.status|get_order_status=$order_info['status']}
			<if condition="$order_info['total_price']&& $order_info['status'] eq 1">&nbsp;&nbsp;消费金额:{$order_info.total_price}</if>
			<if condition="$order_info['order_tip'] && $order_info['status'] eq 2">失败原因：{$order_info.order_tip}</if>
		</td>
	</tr>
	<tr>
	  <td class="item_title">下单时间： </td>
	  <td class="item_input">{$order_info.create_time|to_date}</td>
  </tr>	
	<tr>
		<td rowspan="2" class="item_title">下单人信息：</td>
		<td class="item_input" colspan="3">
			手机:{$order_info.tel}
		</td>
	</tr>
	<tr>
		<td class="item_input" colspan="3">
			姓名:{$order_info.contacter} <if condition="$order_info['sex'] eq 1">先生<else/>女士</if>
		</td>									
	</tr>
	<tr>
		<td class="item_title">订单信息：</td>
		<td class="item_input" colspan="3">
			{$order_info.order_info}<br>
		</td>
	</tr>
	<tr>
		<td class="item_title">订单总额：</td>
		<td class="item_input" colspan="3">
			{$order_info.total_price}<br>
		</td>
	</tr>
	<tr>
		<td class="item_title">送餐地址：</td>
		<td class="item_input" colspan="3">
			{$order_info.address}<br>
		</td>
	</tr>						
	<tr>
		<td class="item_title" >
		订单备注：									
		</td>									
		<td style="text-align: left;" class="item_input" colspan="3">
		{$order_info.msg}
		</td>
	</tr>
	
	<tr>
		<td class="item_title">订单操作</td>
		<td colspan="3" class="item_input">
			<if condition="$order_info['status'] lt 1">
				<input type="button" class="button" value="撤销订单" onclick="viewCancelBox({$order_info.id});"  />
			</if>
			<input type="button" class="button" value="返回订单列表"  onclick="location.href='__APP__?m=TakeawayOrder&a=index';"  />
		</td>
	</tr>
	<tr>
		<td colspan=4 class="bottomTd"></td>
	</tr>
</table>
<div class="blank5"></div>
</div>
<include file="Public:footer" />